3.1293 \(\int \frac{(a+b \tan ^{-1}(c x)) (d+e \log (1+c^2 x^2))}{x^3} \, dx\)

Optimal. Leaf size=154 \[ \frac{1}{2} i b c^2 e \text{PolyLog}(2,-i c x)-\frac{1}{2} i b c^2 e \text{PolyLog}(2,i c x)-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (e \log \left (c^2 x^2+1\right )+d\right )}{2 x^2}-\frac{1}{2} a c^2 e \log \left (c^2 x^2+1\right )+a c^2 e \log (x)-\frac{b c \left (e \log \left (c^2 x^2+1\right )+d\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (e \log \left (c^2 x^2+1\right )+d\right )+b c^2 e \tan ^{-1}(c x) \]

[Out]

b*c^2*e*ArcTan[c*x] + a*c^2*e*Log[x] - (a*c^2*e*Log[1 + c^2*x^2])/2 - (b*c*(d + e*Log[1 + c^2*x^2]))/(2*x) - (
b*c^2*ArcTan[c*x]*(d + e*Log[1 + c^2*x^2]))/2 - ((a + b*ArcTan[c*x])*(d + e*Log[1 + c^2*x^2]))/(2*x^2) + (I/2)
*b*c^2*e*PolyLog[2, (-I)*c*x] - (I/2)*b*c^2*e*PolyLog[2, I*c*x]

________________________________________________________________________________________

Rubi [A]  time = 0.140145, antiderivative size = 154, normalized size of antiderivative = 1., number of steps used = 10, number of rules used = 9, integrand size = 26, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.346, Rules used = {4852, 325, 203, 5021, 801, 635, 260, 4848, 2391} \[ \frac{1}{2} i b c^2 e \text{PolyLog}(2,-i c x)-\frac{1}{2} i b c^2 e \text{PolyLog}(2,i c x)-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (e \log \left (c^2 x^2+1\right )+d\right )}{2 x^2}-\frac{1}{2} a c^2 e \log \left (c^2 x^2+1\right )+a c^2 e \log (x)-\frac{b c \left (e \log \left (c^2 x^2+1\right )+d\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (e \log \left (c^2 x^2+1\right )+d\right )+b c^2 e \tan ^{-1}(c x) \]

Antiderivative was successfully verified.

[In]

Int[((a + b*ArcTan[c*x])*(d + e*Log[1 + c^2*x^2]))/x^3,x]

[Out]

b*c^2*e*ArcTan[c*x] + a*c^2*e*Log[x] - (a*c^2*e*Log[1 + c^2*x^2])/2 - (b*c*(d + e*Log[1 + c^2*x^2]))/(2*x) - (
b*c^2*ArcTan[c*x]*(d + e*Log[1 + c^2*x^2]))/2 - ((a + b*ArcTan[c*x])*(d + e*Log[1 + c^2*x^2]))/(2*x^2) + (I/2)
*b*c^2*e*PolyLog[2, (-I)*c*x] - (I/2)*b*c^2*e*PolyLog[2, I*c*x]

Rule 4852

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[((d*x)^(m + 1)*(a + b*ArcTa
n[c*x])^p)/(d*(m + 1)), x] - Dist[(b*c*p)/(d*(m + 1)), Int[((d*x)^(m + 1)*(a + b*ArcTan[c*x])^(p - 1))/(1 + c^
2*x^2), x], x] /; FreeQ[{a, b, c, d, m}, x] && IGtQ[p, 0] && (EqQ[p, 1] || IntegerQ[m]) && NeQ[m, -1]

Rule 325

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[((c*x)^(m + 1)*(a + b*x^n)^(p + 1))/(a*
c*(m + 1)), x] - Dist[(b*(m + n*(p + 1) + 1))/(a*c^n*(m + 1)), Int[(c*x)^(m + n)*(a + b*x^n)^p, x], x] /; Free
Q[{a, b, c, p}, x] && IGtQ[n, 0] && LtQ[m, -1] && IntBinomialQ[a, b, c, n, m, p, x]

Rule 203

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTan[(Rt[b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 5021

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))*((d_.) + Log[(f_.) + (g_.)*(x_)^2]*(e_.))*(x_)^(m_.), x_Symbol] :> With
[{u = IntHide[x^m*(a + b*ArcTan[c*x]), x]}, Dist[d + e*Log[f + g*x^2], u, x] - Dist[2*e*g, Int[ExpandIntegrand
[(x*u)/(f + g*x^2), x], x], x]] /; FreeQ[{a, b, c, d, e, f, g}, x] && IntegerQ[m] && NeQ[m, -1]

Rule 801

Int[(((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_)))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Int[ExpandIntegrand[(
(d + e*x)^m*(f + g*x))/(a + c*x^2), x], x] /; FreeQ[{a, c, d, e, f, g}, x] && NeQ[c*d^2 + a*e^2, 0] && Integer
Q[m]

Rule 635

Int[((d_) + (e_.)*(x_))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Dist[d, Int[1/(a + c*x^2), x], x] + Dist[e, Int[x/
(a + c*x^2), x], x] /; FreeQ[{a, c, d, e}, x] &&  !NiceSqrtQ[-(a*c)]

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rule 4848

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))/(x_), x_Symbol] :> Simp[a*Log[x], x] + (Dist[(I*b)/2, Int[Log[1 - I*c*x
]/x, x], x] - Dist[(I*b)/2, Int[Log[1 + I*c*x]/x, x], x]) /; FreeQ[{a, b, c}, x]

Rule 2391

Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> -Simp[PolyLog[2, -(c*e*x^n)]/n, x] /; FreeQ[{c, d,
 e, n}, x] && EqQ[c*d, 1]

Rubi steps

\begin{align*} \int \frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{x^3} \, dx &=-\frac{b c \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (d+e \log \left (1+c^2 x^2\right )\right )-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x^2}-\left (2 c^2 e\right ) \int \left (\frac{-a-b c x}{2 x \left (1+c^2 x^2\right )}-\frac{b \tan ^{-1}(c x)}{2 x}\right ) \, dx\\ &=-\frac{b c \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (d+e \log \left (1+c^2 x^2\right )\right )-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x^2}-\left (c^2 e\right ) \int \frac{-a-b c x}{x \left (1+c^2 x^2\right )} \, dx+\left (b c^2 e\right ) \int \frac{\tan ^{-1}(c x)}{x} \, dx\\ &=-\frac{b c \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (d+e \log \left (1+c^2 x^2\right )\right )-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x^2}-\left (c^2 e\right ) \int \left (-\frac{a}{x}+\frac{c (-b+a c x)}{1+c^2 x^2}\right ) \, dx+\frac{1}{2} \left (i b c^2 e\right ) \int \frac{\log (1-i c x)}{x} \, dx-\frac{1}{2} \left (i b c^2 e\right ) \int \frac{\log (1+i c x)}{x} \, dx\\ &=a c^2 e \log (x)-\frac{b c \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (d+e \log \left (1+c^2 x^2\right )\right )-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x^2}+\frac{1}{2} i b c^2 e \text{Li}_2(-i c x)-\frac{1}{2} i b c^2 e \text{Li}_2(i c x)-\left (c^3 e\right ) \int \frac{-b+a c x}{1+c^2 x^2} \, dx\\ &=a c^2 e \log (x)-\frac{b c \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (d+e \log \left (1+c^2 x^2\right )\right )-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x^2}+\frac{1}{2} i b c^2 e \text{Li}_2(-i c x)-\frac{1}{2} i b c^2 e \text{Li}_2(i c x)+\left (b c^3 e\right ) \int \frac{1}{1+c^2 x^2} \, dx-\left (a c^4 e\right ) \int \frac{x}{1+c^2 x^2} \, dx\\ &=b c^2 e \tan ^{-1}(c x)+a c^2 e \log (x)-\frac{1}{2} a c^2 e \log \left (1+c^2 x^2\right )-\frac{b c \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x}-\frac{1}{2} b c^2 \tan ^{-1}(c x) \left (d+e \log \left (1+c^2 x^2\right )\right )-\frac{\left (a+b \tan ^{-1}(c x)\right ) \left (d+e \log \left (1+c^2 x^2\right )\right )}{2 x^2}+\frac{1}{2} i b c^2 e \text{Li}_2(-i c x)-\frac{1}{2} i b c^2 e \text{Li}_2(i c x)\\ \end{align*}

Mathematica [A]  time = 0.11815, size = 189, normalized size = 1.23 \[ -\frac{-i b c^2 e x^2 \text{PolyLog}(2,-i c x)+i b c^2 e x^2 \text{PolyLog}(2,i c x)-2 a c^2 e x^2 \log (x)+a c^2 e x^2 \log \left (c^2 x^2+1\right )+a e \log \left (c^2 x^2+1\right )+a d+b c^2 d x^2 \tan ^{-1}(c x)+b c e x \log \left (c^2 x^2+1\right )-2 b c^2 e x^2 \tan ^{-1}(c x)+b c^2 e x^2 \log \left (c^2 x^2+1\right ) \tan ^{-1}(c x)+b e \log \left (c^2 x^2+1\right ) \tan ^{-1}(c x)+b c d x+b d \tan ^{-1}(c x)}{2 x^2} \]

Antiderivative was successfully verified.

[In]

Integrate[((a + b*ArcTan[c*x])*(d + e*Log[1 + c^2*x^2]))/x^3,x]

[Out]

-(a*d + b*c*d*x + b*d*ArcTan[c*x] + b*c^2*d*x^2*ArcTan[c*x] - 2*b*c^2*e*x^2*ArcTan[c*x] - 2*a*c^2*e*x^2*Log[x]
 + a*e*Log[1 + c^2*x^2] + b*c*e*x*Log[1 + c^2*x^2] + a*c^2*e*x^2*Log[1 + c^2*x^2] + b*e*ArcTan[c*x]*Log[1 + c^
2*x^2] + b*c^2*e*x^2*ArcTan[c*x]*Log[1 + c^2*x^2] - I*b*c^2*e*x^2*PolyLog[2, (-I)*c*x] + I*b*c^2*e*x^2*PolyLog
[2, I*c*x])/(2*x^2)

________________________________________________________________________________________

Maple [F]  time = 11.976, size = 0, normalized size = 0. \begin{align*} \int{\frac{ \left ( a+b\arctan \left ( cx \right ) \right ) \left ( d+e\ln \left ({c}^{2}{x}^{2}+1 \right ) \right ) }{{x}^{3}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*arctan(c*x))*(d+e*ln(c^2*x^2+1))/x^3,x)

[Out]

int((a+b*arctan(c*x))*(d+e*ln(c^2*x^2+1))/x^3,x)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} -\frac{1}{2} \,{\left ({\left (c \arctan \left (c x\right ) + \frac{1}{x}\right )} c + \frac{\arctan \left (c x\right )}{x^{2}}\right )} b d - \frac{1}{2} \,{\left (c^{2}{\left (\log \left (c^{2} x^{2} + 1\right ) - \log \left (x^{2}\right )\right )} + \frac{\log \left (c^{2} x^{2} + 1\right )}{x^{2}}\right )} a e + \frac{{\left (2 \, c^{4} x^{2} \int \frac{x \arctan \left (c x\right )}{c^{2} x^{2} + 1}\,{d x} + 2 \, c^{2} x^{2} \arctan \left (c x\right ) + 2 \, c^{2} x^{2} \int \frac{\arctan \left (c x\right )}{c^{2} x^{3} + x}\,{d x} -{\left (c x +{\left (c^{2} x^{2} + 1\right )} \arctan \left (c x\right )\right )} \log \left (c^{2} x^{2} + 1\right )\right )} b e}{2 \, x^{2}} - \frac{a d}{2 \, x^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*arctan(c*x))*(d+e*log(c^2*x^2+1))/x^3,x, algorithm="maxima")

[Out]

-1/2*((c*arctan(c*x) + 1/x)*c + arctan(c*x)/x^2)*b*d - 1/2*(c^2*(log(c^2*x^2 + 1) - log(x^2)) + log(c^2*x^2 +
1)/x^2)*a*e + 1/2*(4*c^4*x^2*integrate(1/2*x*arctan(c*x)/(c^2*x^2 + 1), x) + 2*c^2*x^2*arctan(c*x) + 4*c^2*x^2
*integrate(1/2*arctan(c*x)/(c^2*x^3 + x), x) - (c*x + (c^2*x^2 + 1)*arctan(c*x))*log(c^2*x^2 + 1))*b*e/x^2 - 1
/2*a*d/x^2

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{b d \arctan \left (c x\right ) + a d +{\left (b e \arctan \left (c x\right ) + a e\right )} \log \left (c^{2} x^{2} + 1\right )}{x^{3}}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*arctan(c*x))*(d+e*log(c^2*x^2+1))/x^3,x, algorithm="fricas")

[Out]

integral((b*d*arctan(c*x) + a*d + (b*e*arctan(c*x) + a*e)*log(c^2*x^2 + 1))/x^3, x)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\left (a + b \operatorname{atan}{\left (c x \right )}\right ) \left (d + e \log{\left (c^{2} x^{2} + 1 \right )}\right )}{x^{3}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*atan(c*x))*(d+e*ln(c**2*x**2+1))/x**3,x)

[Out]

Integral((a + b*atan(c*x))*(d + e*log(c**2*x**2 + 1))/x**3, x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (b \arctan \left (c x\right ) + a\right )}{\left (e \log \left (c^{2} x^{2} + 1\right ) + d\right )}}{x^{3}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*arctan(c*x))*(d+e*log(c^2*x^2+1))/x^3,x, algorithm="giac")

[Out]

integrate((b*arctan(c*x) + a)*(e*log(c^2*x^2 + 1) + d)/x^3, x)